<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE HTML>

<html xmlns="http://www.w3.org/1999/xhtml" lang="">

	<head>

		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

		<meta http-equiv="X-UA-Compatible" content="IE=Edge"/>

		<meta name="viewport" content="width=device-width,initial-scale=1,user-scalable=no">

		<title><?php echo C('WEB_TITLE');?></title>

		<link rel="stylesheet" type="text/css" href="/Public/css/common.css"/>

		<link rel="stylesheet" type="text/css" href="/Public/js/layui/css/layui.css" media="all"/>

		<link rel="stylesheet" type="text/css" href="/Public/index/css/index.css"/>

		<link rel="stylesheet" type="text/css" href="/Public/index/css/style.css"/>

		<link rel="stylesheet" href="<?php echo C('PC_ICON_HTTP');?>">

		<script type="text/javascript" >

			const moduleName = "<?php echo (MODULE_NAME); ?>";

		</script>

        <link rel="stylesheet" href="/Public/js/viewer/css/viewer.min.css">

		<script type="text/javascript" src="/Public/js/jquery-1.9.1.min.js"></script>

		<script type="text/javascript" src="/Public/js/jquery-ui.min.js"></script>

		<script type="text/javascript" src="/Public/js/cookie/jquery.cookie.js"></script>

		<script type="text/javascript" src="/Public/js/lang/<?php echo (getStrToLower(cookie('think_language'))); ?>.js"></script>

		<script type="text/javascript" src="/Public/js/colorpicker.js"></script>

		<script type="text/javascript" src="/Public/js/layer/layer.js"></script>

		<script type="text/javascript" src="/Public/js/layui/layui.js"></script>

		<script type="text/javascript" src="/Public/js/jquery.nicescroll.js"></script>

		<script type="text/javascript" src="/Public/js/clipboard.min.js"></script>

        <script type="text/javascript" src="/Public/js/feeldesk.js"></script>
<!--
		<script type="text/javascript" src="/Public/js/signature/flashcanvas.js"></script>

		<script type="text/javascript" src="/Public/js/signature/signature.min.js"></script>
-->

        <script type="text/javascript" src="/Public/index/js/index.js"></script>

<!--		<script type="text/javascript" src="/Public/js/Lodop/LodopFuncs.js"></script>-->

		<script type="text/javascript" src="/Public/js/xm-select/xm-select.js"></script>

	</head>

    <body>


<div class="window-form">

    

    <form action="" class="layui-form">

        <div class="form-item">

            <div class="layui-form-item">

                <label class="layui-form-label"><?php echo L('SUBORDINATE_SECTOR');?></label>

                <div class="layui-input-inline" id="departments"></div>

            </div>

            <div class="layui-form-item">

                <label class="layui-form-label"><?php echo L('ROLE');?></label>

                <div class="layui-input-inline">

                    <select id="content" name="member[role_id]">

                        <option value="0"><?php echo L('SELECT_ROLE');?></option>

                        <?php if(is_array($roles)): foreach($roles as $key=>$val): ?><option value="<?php echo ($val["role_id"]); ?>"><?php echo ($val["role_name"]); ?></option><?php endforeach; endif; ?>

                    </select>

                </div>

            </div>

            <div class="layui-form-item">

                <label class="layui-form-label"><?php echo L('ACCOUNT');?></label>

                <div class="layui-input-inline">

                    <input type="text" name="member[account]" value="" class="layui-input" placeholder="<?php echo L('USERNAME_NOTE');?>" />

                </div>

            </div>

            <div class="layui-form-item">

                <label class="layui-form-label"><?php echo L('PASSWORD');?></label>

                <div class="layui-input-inline">

                    <input type="password" name="member[password]" id="password" value="" class="layui-input" placeholder="<?php echo L('PASSWORD_NOTE');?>" title="<?php echo L('CODE_NOTE');?>"/>

                </div>

            </div>

            <div class="layui-form-item">

                <label class="layui-form-label"><?php echo L('NAME');?></label>

                <div class="layui-input-inline">

                    <input type="text" name="member[name]" value="" class="layui-input" placeholder="<?php echo L('NAME');?>"/>

                </div>

            </div>

            <div class="layui-form-item">

                <label class="layui-form-label"><?php echo L('NICKNAME');?></label>

                <div class="layui-input-inline">

                    <input type="text" name="member[nickname]" value="" class="layui-input" placeholder="<?php echo L('NICKNAME');?>"/>

                </div>

            </div>

            <div class="layui-form-item">

                <label class="layui-form-label"><?php echo L('WECHAT_NUMBER');?></label>

                <div class="layui-input-inline">

                    <input type="text" name="member[wechat]" value="" class="layui-input" placeholder="<?php echo L('ENTER_WECHAT_NUMBER');?>" />

                </div>

            </div>

            <?php if(!empty($workphone)): ?><div class="layui-form-item">

                    <label class="layui-form-label">AccountSecret</label>

                    <div class="layui-input-inline">

                        <input type="text" name="member[accountsecret]" value="" class="layui-input"/>

                    </div>

                </div><?php endif; ?>

<!--

            <div class="layui-form-item">

                <label class="layui-form-label"><?php echo L('SUBORDINATE_SECTOR');?></label>

                <div class="layui-input-inline">

                    <?php if(is_array($groups)): foreach($groups as $key=>$val): ?><input type="checkbox" name="member[group_id][]" value="<?php echo ($val["group_id"]); ?>" lay-skin="primary" title="<?php echo ($val["group_name"]); ?>"/><?php endforeach; endif; ?>

                </div>

            </div>
-->

            <div class="layui-form-item">

                <label class="layui-form-label"><?php echo L('IS_ENABLE');?></label>

                <div class="layui-input-inline w-auto">

                    <input type="radio" name="member[closed]" value="0" title="<?php echo L('ENABLE');?>">

                    <input type="radio" name="member[closed]" value="1" title="<?php echo L('DISABLE');?>">

                </div>

            </div>

        </div>

        <div class="form-submit">

            <div class="layui-form-item">

                <div class="layui-input-inline">

                    <a href="javascript:" class="layui-btn layui-btn-normal" id="submitForm"><?php echo L('SUBMIT');?></a>

                    <a href="javascript:" class="layui-btn layui-btn-normal cancel-btn" id="cancel-form"><?php echo L('CANCEL');?></a>

                </div>

            </div>

        </div>

    </form>

    <script type="text/javascript">

        layui.config({
            base : '/Public/js/layui/extends/'
        }).extend({
            selectN: 'selectM'
        }).use(['form','selectM'],function()
        {
            var form = layui.form;

            var data = JSON.parse('<?php echo ($jsonDepartmentData); ?>');

            layui.selectM(
            {
                elem: '#departments',
                data: data,
                tips:"<?php echo L('PLEASE_SELECT');?>",
                width:'100%',
                name:'group_id',
                field: {idName:'group_id',titleName:'group_name',statusName:'status',levelName:'level',childName:'child'},
                search:true,
                searchTips:"<?php echo L('PLEASE_ENTER_KEYWORDS');?>",
                max:100
            });
        });

    </script>



</div>

<script type="text/javascript" src="/Public/js/submitform.js"></script>